projects
/
project
/
libubox.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
325fea5
)
udebug: add inline helper function to test if a buffer is allocated
author
Felix Fietkau
<
[email protected]
>
Wed, 29 Nov 2023 21:00:19 +0000
(22:00 +0100)
committer
Felix Fietkau
<
[email protected]
>
Wed, 29 Nov 2023 21:00:19 +0000
(22:00 +0100)
Signed-off-by: Felix Fietkau <
[email protected]
>
udebug.h
patch
|
blob
|
history
diff --git
a/udebug.h
b/udebug.h
index 75c2e3f916701bf0e86f757e912e8b2a8afa5a62..3b6c85154f3e75727e42ea7e066022e277d33ea7 100644
(file)
--- a/
udebug.h
+++ b/
udebug.h
@@
-166,6
+166,10
@@
int udebug_buf_add(struct udebug *ctx, struct udebug_buf *buf,
const struct udebug_buf_meta *meta);
uint64_t udebug_buf_flags(struct udebug_buf *buf);
void udebug_buf_free(struct udebug_buf *buf);
+static inline bool udebug_buf_valid(struct udebug_buf *buf)
+{
+ return buf->hdr;
+}
struct udebug_remote_buf *udebug_remote_buf_get(struct udebug *ctx, uint32_t id);
int udebug_remote_buf_map(struct udebug *ctx, struct udebug_remote_buf *rb, uint32_t id);